home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 8: LINUX Games / Linux Cubed Series 8 - LINUX Games.iso / games / x11 / rpg / crossfir.001 / crossfir~ / eutl / DOC < prev    next >
Text File  |  1995-10-29  |  1KB  |  24 lines

  1. This is partial documentation on some of the functions.  I figured I should
  2. at least write down what I have figured out the different functions do:
  3.  
  4. WaitForInput( TcpSocket *socks, int nsocks, long msTimeout)
  5. This function processes the sockets - socks is an array, with nsocks
  6. containing the number of active elements.  This function will go
  7. through and do all the selects and other low level stuff on the sockets.
  8. It also updateds numerous flags, including the input flag that HasInput uses.
  9.  
  10. HasInput(TcpSocket sock):  This returns true if the socket has input waiting
  11. - note that is is actually information that is stored in sock's buffer.
  12. WaitForInput updates this value - thus it will still return true even after
  13. reading the data out until another WaitForInput has been called.
  14. Unfortunately, there does not seem to be any way to tell if all the
  15. information has been processed short of calling WaitForInput and HasInput
  16. again.
  17.  
  18. Arg* functions:  They create an arbitrary long list, that can then be
  19. sent over the connection.  Unforunately, there is a fair amount of cpu overhead
  20. on all of these functions (because each time you use an add function, it
  21. does another malloc).  Also, note that everything sent also has a 4 byte
  22. length indicator to it.  Thus, while the data may only be 4 bytes, 4 bytes
  23. more get added to it for the length,
  24.